import React, { PureComponent } from 'react'
import { ImageBackground, StyleSheet, View, Image, Text } from 'react-native'
import { screen, system } from '../../common'
type Props = {
    info: Object,
}
type State = {
}
class DiscountCouponIssueItem extends PureComponent<Props, State>{
    render() {
        let info = this.props.info
        let price = info.price
        let useLimit = info.uselimit
        let endUseTime = info.endusetime
        let title=info.title
        return (
            <View>
                <View style={styles.container}>
                    <View style={styles.leftStyle}>
                        <View style={styles.priceStyle}>
                            <Text style={styles.symbolStyle}>¥ </Text>
                            <Text style={styles.figureStyle}>{price}</Text>
                        </View>
                        <Text style={styles.useLimitStyle}>{useLimit}</Text>
                    </View>
                    <View style={{ height: screen.height/(9.5),width: 2, backgroundColor: '#C0C0C0' }}></View>
                    <View style={styles.rightStyle}>
                        <Text style={styles.titleStyle}>{title}</Text>
                        <Text style={styles.endTimeStyle}>有效期至{endUseTime}</Text>
                    </View>
                </View>
                <View style={{ height: 5, backgroundColor: 'transparent' }}></View>
            </View>
        )
    }
}
const styles = StyleSheet.create({
    container: {
        flexDirection: 'row',
        // padding: 10,
        height: screen.height/(9.5),
        width: screen.width*0.7,
        //marginLeft: 50,
        // justifyContent: 'flex-start',
        // alignItems: 'flex-start',
        backgroundColor:'white',
        borderRadius: 10,
    },
    leftStyle: {
        height: screen.height/(9.5),
        width: screen.width*0.7/3,
        justifyContent: 'center',
        alignItems: 'center',
        // paddingLeft: 20,
       // marginLeft:20,
        // backgroundColor:'yellow'
    },
    priceStyle: {
    flexDirection: 'row',
        // backgroundColor: 'blue',
        justifyContent: 'center',
        alignItems: 'center',
    },
    symbolStyle: {
        fontSize: 20,
        color:'red',
        // marginTop: 10,
        // backgroundColor: 'yellow',
        // alignItems: 'flex-end',
    },
    figureStyle:{
        fontSize: 30,
        color:'red',
        fontWeight: 'bold',
    },
    useLimitStyle:{
        fontSize:18,
        // fontWeight: 'bold',
        color:'black',
        // textAlign: 'center',
        // justifyContent: 'center',
        // alignItems: 'center',
        // backgroundColor:'green'
    },
    rightStyle: {
        height: screen.height/(9.5),
        width: screen.width*1.4/3,
        // flexDirection: 'row',
        justifyContent: 'center',
        // alignItems: 'center',
        // padding:10,
        marginLeft:30,
    },
    titleStyle: {
        fontSize: 20,
        // marginBottom: 3,
        // fontWeight: 'bold',
        color:'black',
    },
    endTimeStyle:{
        fontSize:18,
        color:'#808A87',
    },
    
    
    



})
export default DiscountCouponIssueItem